package cn.afei.cloud.utils.result;


/**
 * 返回结果的枚举类
 */

public enum ResultEnum {

    SUCCESS(0, "success"),
    NOT_NETWORK(-1, "系统繁忙，请稍后再试。"),
    LOGIN_VERIFY_FALL(2, "登录信息已失效"),
    PARAM_VERIFY_FALL(3, "参数验证错误"),
    AUTH_FAILED(4, "权限验证失败"),
    DATA_NOT(5, "没有相关数据"),
    DATA_CHANGE(6, "数据没有任何更改"),
    DATA_REPEAT(7, "数据已存在"),
    PRE_ADMIN(8, "请先删除对应的管理员"),
    EXECUTION_SUCCESS_MESSAGE(66,"操作成功"),
    EXECUTION_FAILURE_MESSAGE(99,"操作失败"),
    NOT_RESOURCES(9,"资源路径不存在"),
    BACKUPS_FAILURE(10,"备份数据库失败"),
    RESTORE_FAILURE(11,"恢复数据库失败"),
    SYSTEM_CLOSE(-2,"您的账号已被禁止登录"),
    SYSTEM_END(-3,"您的登录账号已到期"),
    TEXT_VIOLATIONS(4, "操作失败,含有违规数据!"),
    MATE_NULL(100,"暂未匹配到相应的用户"),
    CLIENT_ERROR(-4, "ClientId或SecretId错误");


    private Integer code;

    private String message;

    ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
